package com.bonuo.saas.service.impl;

import com.bonuo.saas.domain.IntellectualProperty;
import com.bonuo.saas.domain.IntellectualPropertyFile;
import com.bonuo.saas.domain.WorkorderSynergy;
import com.bonuo.saas.mapper.IntellectualPropertyFileMapper;
import com.bonuo.saas.mapper.IntellectualPropertyMapper;
import com.bonuo.saas.service.IntellectualPropertyService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.*;

@Service
public class IntellectualPropertyServiceImpl implements IntellectualPropertyService {

    @Autowired
    private IntellectualPropertyMapper intellectualPropertyMapper;


    @Override
    public List<IntellectualProperty> selectIntellectualPropertyList(IntellectualProperty intellectualProperty) {
        List<IntellectualProperty> intellectualProperties = intellectualPropertyMapper.selectIntellectualPropertyList(intellectualProperty);
        return intellectualProperties;
    }

    @Override
    public int insertIntellectualProperty(IntellectualProperty intellectualProperty) {
        int i = intellectualPropertyMapper.insertIntellectualProperty(intellectualProperty);
        return i;
    }

    @Override
    public int updateIntellectualProperty(IntellectualProperty intellectualProperty) {
        int i = intellectualPropertyMapper.updateIntellectualProperty(intellectualProperty);
        return i;
    }

    @Override
    public int deleteIntellectualPropertyById(Integer id) {
        int i = intellectualPropertyMapper.deleteIntellectualPropertyById(id);
        return i;
    }

    @Override
    public String selectIntellectualPropertyByRegistrationNumber(IntellectualProperty intellectualProperty) {
        return intellectualPropertyMapper.selectIntellectualPropertyByRegistrationNumber(intellectualProperty);
    }

    @Override
    public Integer selectCopyrightCount() {
        return intellectualPropertyMapper.selectCopyrightCount();
    }

    @Override
    public Integer selectPatentCount(Integer patentType) {
        return intellectualPropertyMapper.selectPatentCount(patentType);
    }
}
